package com.sfeir.tv.client.mvc.framework.impl.gwt;

import com.google.gwt.user.client.Event;
import com.google.gwt.user.client.ui.AbsolutePanel;
import com.google.gwt.user.client.ui.Widget;

public abstract class GWTAbsolutePanel extends GWTPanel {
    
    public GWTAbsolutePanel(String id) {
        super(id);
        panel = new AbsolutePanel(){
            public void onBrowserEvent(Event event) {
                onGWTBrowserEvent( event );
                super.onBrowserEvent(event);
            }
        };
        initWidget(panel);
        panel.setHeight("800px");
        panel.sinkEvents(Event.MOUSEEVENTS);
    }

    public void add(Widget widget, int left, int top) {
    	((AbsolutePanel)panel).add(widget, left, top);
    }

    public void add(Widget widget) {
    	panel.add(widget);
    }
}
